﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DemoConstructor.Demo1
{
    /// <summary>
    /// Inheritance constructor.
    /// </summary>
    class Demo1
    {
        public static void RunDemo1()
        {
            ThirdClass theThird = new ThirdClass();
        }
    }

    class FirstClass //: Object
    {
        public FirstClass()
        {
            Console.WriteLine("FirstClass was created.");
        }
    }

    class SecondClass : FirstClass
    {
        public SecondClass()
        {
            Console.WriteLine("SecondClass was created.");
        }
    }

    class ThirdClass : SecondClass
    {
        public ThirdClass()
        {
            Console.WriteLine("ThirdClass was created.");
        }
    }
}
